
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html>
<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="UTF-8"%>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<link href="css/Login.css" rel="stylesheet" type="text/css"></link>
<script src="js/LazyRig/jquery.js"></script>
</head>


<%
	String email1 = (String) session.getAttribute("email");
	String getCook = null;
	Cookie[] cookies = request.getCookies();
	if (cookies != null) {
		for (int i = 0; i < cookies.length; i++) {
			if (cookies[i].getName().equals("email")) {
				getCook = cookies[i].getValue();
				break;
			}
		}
	}
%>
<body>
	<div class="login-bar">
		<%
			if (email1 == null && getCook == null) {
		%>
		<a href="#" class="login-button"
			onmouseover="d.src='image/imageWeb/choingay-dangkyHover.png'"
			onmouseout="d.src='image/imageWeb/choingay-dangky.png'"><img
			src="image/imageWeb/choingay-dangky.png" name="d" border="0" /></a>
		<div style=""></div>
	</div>
	<div class="overlaylogin"></div>
	<div class="login">
		<div class="login-header">
			<img src="image/imageWeb/close-btn.png" class="closelogin" />
		</div>
		<div class="login-content">
			<%@ include file="login2.jsp"%>
		</div>
	</div>
	<%
		} else {
	%>

	<div>
		<div
			style="background-image: url('image/imageWeb/2733955_2012120709025210UkU.png'); height: 100px; width: 160px; float: left;">
			<a href="accountManager.jsp"><div
					style="font-size: 15px; color: white; width: 160px; height: 50px; margin-top: 35px; margin-left: 16px;">Quản
					Lí Tài Khoản</div></a>
		</div>
		<a href="Logout" onmouseover="d2.src='image/imageWeb/LogOut.png'"
			onmouseout="d2.src='image/imageWeb/LogOut1Hover.png'"><img
			src="image/imageWeb/LogOut1Hover.png" name="d2" border="0" /></a>
	</div>
	<%
		}
	%>
	<script>
		(function($) {
			var overlay = $('.overlaylogin');
			var login = $('.login');
			var body = $('body');
			$('.login-button').click(function(e) {
				e.preventDefault();
				body.css({
					'overflowlogin' : 'hidden'
				});
				overlay.fadeIn(500, function() {
					login.fadeIn(500);
				})
			});

			$('.closelogin').click(function(e) {
				e.preventDefault();
				login.fadeOut(500, function() {
					overlay.fadeOut(500);
					body.css({
						'overflowlogin' : 'visible'
					});
				})
			})
		})(jQuery);
	</script>

</body>
</html>
